import { createRouter, createWebHashHistory } from 'vue-router'
import Home from '../views/Home.vue'
import layout from '../components/menu'
const routes = [
  {
    path: '/',
    name: 'Home',
    component: layout,
    children: [
      {
        path: '/about',
        name: 'About',
        // route level code-splitting
        // this generates a separate chunk (about.[hash].js) for this route
        // which is lazy-loaded when the route is visited.
        component: () => import(/* webpackChunkName: "about" */ '../views/About.vue')
      },
      {
        path: '/setup',
        name: 'setup',
        component: () => import(/* webpackChunkName: "about" */ '../views/setupView.vue')
      },
      {
        path: '/refData',
        name: 'refData',
        component: () => import(/* webpackChunkName: "about" */ '../views/refData.vue')
      },
      {
        path: '/roRef',
        name: 'roRef',
        component: () => import(/* webpackChunkName: "about" */ '../views/roRef.vue')
      },
      {
        path: '/provide',
        name: 'provide',
        component: () => import(/* webpackChunkName: "about" */ '../views/provide.vue')
      }
    ]
  },

]

const router = createRouter({
  history: createWebHashHistory(),
  routes
})

export default router
